# -*- coding: utf-8 -*-
from flask import Blueprint,request,jsonify
from common.libs.Helper import osp_render
from common.libs.Helper import getCurrentDate
from common.models.Storage import Storage
from application import db,app
route_storagy = Blueprint( 'storagy_page',__name__ )

@route_storagy.route( "/index" )
def index():
    resq_data = {}
    query = Storage.query
    list = query.order_by(Storage.sid.desc()).all()#全量查询，倒叙排列
    resq_data['list'] = list
    resq_data['count'] = query.count()
    return osp_render( "storagy/index.html",resq_data)